package com.personal.ifanya.domain.enums;

public enum BizExceptionMsg {

	DAL_INSERT_EXCEPTION("Error occurred while inserting data to database."),
	DAL_QUERY_EXCEPTION("Error occurred while query data from database."),
	DAL_UPDATE_EXCEPTION("Error occurred while updating data to database."),
	INVALID_PARAMETER("Invalid parameters."),
	UNKNOWN_EXCEPTION("Unknown business layer exception.");
	
	final private String message;
	
	private  BizExceptionMsg(String message)
	{
		this.message = message;
	}
	
	public String getMessage()
	{
		return this.message;
	}
	
	
	public String getExMessage(String extraMessage)
	{
		return String.format("%s, Caused by: %s .", this.message, extraMessage);
	}
	
}
